include("inc.php");
if($_GET['gpflg']==1){
$m_id = $_GET['m_id'];
//setcookie("Prime-id",$id,time()-60*60*24*10,"/prime/",".jhayashida.co.jp",0);
setcookie("Prime-id",$m_id,time()+60*60*24,"/prime/",".jhayashida.co.jp",0);
$id = $m_id;
}elseif($_GET['gpflg']==0){
$id=$_GET['id'];
setcookie("Prime-id",$id,time()+60*60*24*10,"/prime/",".jhayashida.co.jp",0);
}
$id = $_COOKIE['Prime-id'];
$pass = $_COOKIE['Prime-pass'];
if($id==""){
$id=$_GET['id'];
}
if($id==""){
if(_S == 1){
header("Location: http://www.blogone.jp/");
}elseif(_S == 0){
header("Location: http://localhost/public/prime/index.php");
}
exit;
}
//MySQLに接続
if(!$conn = mysql_connect(_DB_SERVER,_DB_UID,_DB_PASS)){
die('MySQL接続失敗');
}
//データベースの選択
if(!$sts = mysql_select_db(_DB_NAME,$conn)){
die('テーブル選択失敗');
}
$num=0;
$sqllist="";
$sqllist.="select id from bbs where id = '$id' ";
$sqllist.="group by artnum order by data desc ";
$mqlist = mysql_query($sqllist,$conn);
while($rec = mysql_fetch_array($mqlist)){
$num++;
}
$sqllist="";
$sqllist.="select * from member where id = '$id' group by id";
$mqlist = mysql_query($sqllist,$conn);
if($rec = mysql_fetch_array($mqlist)){
$blogtitle = $rec['blogtitle'];
$ownerskin_id = $rec['skin_id'];
}
$sqllist="";
$sqllist.="select * from profile where id = '$id' group by id";
$mqlist = mysql_query($sqllist,$conn);
if($rec = mysql_fetch_array($mqlist)){
$name = $rec['name'];
$in = $rec['imgname'];
$u1 = "${id}/"."$in".".jpg";
if(file_exists("$u1")){
$img1flg=1;
$percent=0;
//画像サイズ自動変更処理
list($width, $height) = getimagesize("$u1");
if($width > $height){
if($width > 150){
$percent = 150 / $width;
}
}elseif($width < $height){
if($height > 150){
$percent = 150 / $height;
}
}else{
if($width > 150){
$percent = 150 / $width;
}
if($height > 150){
$percent = 150 / $height;
}
}
if($percent > 0){
$new_width1 = $width * $percent;
$new_height1 = $height * $percent;
}else{
$new_width1 = $width;
$new_height1 = $height;
}
}
}
?>
$year = $_COOKIE['year'];
if($year == null){
$year = date("Y");
}
$month = $_COOKIE['month'];
if($month == null){
$month = date("n");
}
$move = $_GET['move'];
switch($move){
case -3 ;
$year -= 10;
break;
case -2 ;
$year -= 1;
break;
case -1 ;
$month -= 1;
if($month < 1){ //月が0以下になったときの処理
$month += 12 ;
$year -= 1;
}
break;
case 0 ;
$year = date("Y");
$month = date("n");
break;
case 1 ;
$month += 1;
if($month > 12){ //月が13以上になったときの処理
$month -=12;
$year += 1;
}
break;
case 2 ;
$year += 1;
break;
case 3 ;
$year += 10;
break;
case 4 ;
$year += 100;
break;
}
setcookie("year",$year,time()+60*60);
setcookie("month",$month,time()+60*60);
$j=date("j");
mb_language("Ja") ;
mb_internal_encoding("JIS") ;
header('content-type: text/html; charset =' ._CHARSET);
?>
Blog One
//更新履歴の表示処理
$rireki = _rireki();
echo "$rireki";
?>
}?>
<< 年月 >> SUN
MON
TUE
WED
THU
FRI
SAT
}else{?>
▼ 投稿リスト(新しいものから順に表示されます。件名をクリックすると投稿内容を確認できます。)
$sqllist="";
$sqllist.="select * from bbs where id = '$id' ";
$sqllist.="group by artnum order by data desc ";
$mqlist = mysql_query($sqllist,$conn);
while($rec = mysql_fetch_array($mqlist)){
$artnum=_hs($rec['artnum']);
$title=_hs($rec['title']);
$date=_hs($rec['data']);
$comnum=0;
$sqlt="";
$sqlt.="select id from bbscom where artnum = '$artnum' ";
$mqlt = mysql_query($sqlt,$conn);
while($rec = mysql_fetch_array($mqlt)){
$comnum++;
}
?>
年月日時分秒
&artnum=">()
&artnum=">削除する
}
?>
}?>